// 根据门店获取车辆
export const reqCarListByShop = (shop_id) =>
  request({ url: `/car/${shop_id}`, method: "get" });

// 添加新车或修改车信息
export const reqAddOrUpdateCar = (data) => {
  if (data._id) {
    return request({ url: "/car", method: "put", data });
  } else {
    return request({ url: "/car", method: "post", data });
  }
};

// 删除类型
export const reqDeleteCar = (data) =>
  request({ url: "/car", method: "delete", data });
